package com.wntms.ywa.web;


import com.wntms.ywa.pojo.FreightContract;
import com.wntms.ywa.service.FreightService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PutMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/add")
//解决跨域问题
//@CrossOrigin
public class ReceiveController {
    @Autowired
    private FreightService freightService;
    @PutMapping
    public void update(@RequestBody FreightContract freightContract){
        freightService.update(freightContract);
        System.out.println(true);
    }




}
